From eae219de6f25fcafa57445d6d763d127ced4abf7 Mon Sep 17 00:00:00 2001 From: "cl349@firebug.cl.cam.ac.uk" Date: Wed, 14 Sep 2005 19:52:04 +0000 Subject: [PATCH] Explicit test for None. Signed-off-by: Christian Limpach --- tools/python/xen/xend/xenstore/xstransact.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tools/python/xen/xend/xenstore/xstransact.py b/tools/python/xen/xend/xenstore/xstransact.py index 94a9bda1bd..62dfc49627 100644 --- a/tools/python/xen/xend/xenstore/xstransact.py +++ b/tools/python/xen/xend/xenstore/xstransact.py @@ -138,10 +138,10 @@ class xstransact: raise TypeError else: (key, val, fmt) = tup - if val: - self._write(key, fmt % val) - else: + if val is None: self._remove(key) + else: + self._write(key, fmt % val) def Read(cls, path, *args): -- 2.30.2